<?php

namespace Shuai\Phpwx\Http\Controllers;
use Encore\Admin\Layout\Content;
use Illuminate\Routing\Controller;
use Shuai\Phpwx\Http\Requst\Requst;
use Shuai\Phpwx\Http\Api\Api;
use Illuminate\Support\Facades\Cache;
class PhpwxController extends Controller
{
    public function index(Content $content)
    {
        return $content
            ->title('Title')
            ->description('Description')
            ->body(view('phpwx::index'));
    }

    public function req(Requst $requst){


        $api = new Api();

        $jscode = "db.collection(\"zanmeidb\").limit(1000).skip(1).get()";

        dd($api->send('databasequery',$jscode)) ;


    }
}
